CREATE TABLE jms_dm.dm_customer_complaint_network_arr_pick_summary_dt
(
    network_code  varchar(100) NULL COMMENT "网点编码",
    name          varchar(100) NULL COMMENT "网点名称",
    center_code   varchar(100) NULL COMMENT "中心编码",
    center_name   varchar(100) NULL COMMENT "中心名称",
    fran_code     varchar(100) NULL COMMENT "加盟商code",
    fran_name     varchar(100) NULL COMMENT "加盟商name",
    agent_code    varchar(100) NULL COMMENT "代理区code",
    agent_name    varchar(100) NULL COMMENT "代理区name",
    virt_code     varchar(100) NULL COMMENT "虚拟代理区code",
    virt_name     varchar(100) NULL COMMENT "虚拟代理区name",
    tak_cnt       int(11) NULL COMMENT "收件量",
    arr_ctn       int(11) NULL COMMENT "到件量",
    date_type     varchar(100) NULL COMMENT "类型1是天2是月",
    district_code varchar(100) NULL COMMENT "片区code",
    district_desc varchar(100) NULL COMMENT "片区名称",
    network_type  varchar(100) NULL COMMENT "网点类型:1-总部,2-代理区,3-加盟商,4-中心,5-集散点,6-网点",
    date_time     date NULL COMMENT "日期",
    district_id   varchar(65533) NULL COMMENT "district_id"
) ENGINE=OLAP
DUPLICATE KEY(network_code)
COMMENT "客诉网点到件量发件量"
PARTITION BY RANGE (date_time) (
    START ("2023-02-01") END ("2023-03-15") EVERY (INTERVAL 1 day)
)
DISTRIBUTED BY HASH(network_code) BUCKETS 1
PROPERTIES (
"replication_num" = "3",
"dynamic_partition.enable" = "true",
"dynamic_partition.time_unit" = "DAY",
"dynamic_partition.time_zone" = "Asia/Shanghai",
"dynamic_partition.start" = "-180",
"dynamic_partition.end" = "3",
"dynamic_partition.prefix" = "p",
"dynamic_partition.buckets" = "1",
"in_memory" = "false",
"storage_format" = "V2"
);